package com.indeep.user.mapper.po;

import com.baomidou.mybatisplus.annotation.*;
import lombok.AllArgsConstructor;
import lombok.Data;
import lombok.NoArgsConstructor;

import java.io.Serializable;
import java.util.Date;

/**
 * @author Laixin
 * @description app_follow
 * @date 2023-08-29
 */
@Data
@AllArgsConstructor
@NoArgsConstructor
@TableName("app_follow")
public class AppFollowPO implements Serializable {

    private static final long serialVersionUID = 10L;

    @TableId(type = IdType.AUTO)
    private Long id;

    /**
     * 用户id
     */
    private Long userId;

    /**
     * 关注的用户id
     */
    private Long followUserId;

    /**
     * 状态0——未关注1——已关注
     */
    private int status;

    /**
     * 创建时间-创建时自动填充
     */
    @TableField(fill = FieldFill.INSERT)
    private Date createTime;

    /**
     * 更新时间-创建与修改时自动填充
     */
    @TableField(fill = FieldFill.INSERT_UPDATE)
    private Date updateTime;

    public AppFollowPO(Long userId, Long followUserId, Integer status) {
        this.userId = userId;
        this.followUserId = followUserId;
        this.status = status;
    }
}